Skip to content

PdfFont Class

Definition

Namespace: Xfinium.Pdf.Graphics

Defines the base class for PDF fonts.

C#
public abstract class PdfFont : Object

Inheritance: Object → PdfFont

Properties

Name Description
Bold Gets or sets a value indicating whether the font is bold.
CharacterSpacing Gets or sets the character spacing to be used by this font.
CosFont Gets the COS font dictionary.
HorizontalScaling Gets or sets the text horizontal scaling to be used by this font.
Italic Gets or sets a value indicating whether the font is italic.
Metrics Gets the font metrics.
Size Gets or sets the font size.
Strikethrough Gets or sets a value indicating whether the font is strikethrough.
StrikethroughOffset Gets or sets the strikethrough offset.
TextRenderingMode Gets or sets the text rendering mode.
Underline Gets or sets a value indicating whether the font is underlined.

Methods

Name Description
EncodeString Encodes the given text to a byte array based on font's encoding.
GetCharWidth Gets the width of the given character when drawn with this font object.